var lis = document.querySelectorAll('li');
var items = document.querySelectorAll('.item') 
console.log(items)
for(var i = 0; i < lis.length; i++){
  lis[i].index = i;
  lis[i].onmouseenter = function(){
    for( var j = 0; j < lis.length; j++){
      lis[j].className = ''
      items[j].style.display = 'none'
    }
    this.className = 'active';
    var num = this.index;
    items[num].style.display = 'block';
    
  }
}